/etc/profile
is systemwide bash profile/etc/bashrc
has bash-specific configurations (so does zshrc
)~/bash_profile
user specific config~/bashrc
read after system wide bashrc, aliases and stuffenv
command.set
command.set -e
sets a bash option
MYVAR="Hello"
defines a local variable in the current shellexport MYVAR
adds it to environment variables which allows child processes to have access, using the bash export
builtinA command is first tokenized, then one of 8 expansions is performed on each token, followed by quote removal.
sp{el, il, al}l
=> spell spill spall
(prefixes and postfixes to each option)$HOME
path$
replaces an expression with its value${PARAMETER}
, the value of "PARAMETER" is substituted"plural: ${WORD}s"
$(command)
or backticks$(( EXPRESSION ))
$[ EXPRESSION ]
performs calculation, no expansion?, no tests